﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using IHISCETeim.DAL;
using IHISCETeim.Model;
using IHISCETeim.Library;
using System.Data;

namespace IHISCETeim.BLL
{
    public class SAP_AgentListController
    {
        public static int Add(SAP_AgentListInfo obj)
        {
            return SAP_AgentListDAL.Add(obj);
        }
        public static bool Delete(string CardCode)
        {
            return SAP_AgentListDAL.Delete(CardCode);
        }
        public static SAP_AgentListInfo GetByCardCode(string CardCode)
        {
            return CBO.FillObject<SAP_AgentListInfo>( SAP_AgentListDAL.GetByCardCode(CardCode));
        }
        public static DataTable GetPagination(string whereSql, int PageIndex, int PageSize, string Sort, ref int TotalCount)
        {
            return SAP_AgentListDAL.GetPagination(whereSql,PageIndex, PageSize, Sort, ref  TotalCount);
        }
        public static bool Update(SAP_AgentListInfo obj)
        {
            return SAP_AgentListDAL.Update(obj);
        }
        /// <summary>
        /// 更新配件接收人信息
        /// </summary>
        /// <param name="obj"></param>
        /// <returns></returns>
        public static bool PJUpdate(SAP_AgentListInfo obj)
        {
            return SAP_AgentListDAL.Update(obj);
        }
    }
}
